package consts

const EMQX_TOPIC_DEVICE_ON = "$SYS/brokers/+/clients/+/connected"     // 上线事件的主题
const EMQX_TOPIC_DEVICE_OFF = "$SYS/brokers/+/clients/+/disconnected" // 下线事件的主题
// 这两个是 mochi-mqtt的上下线通知
const MOCHI_MQTT_DEVICE_ON = "hook/direct/publish/connected/"
const MOCHI_MQTT_DEVICE_OFF = "hook/direct/publish/disconnected/"

const EMQX_TOPIC_PUB = "qciot/ae/new/pub/"             //设备发布消息
const EMQX_TOPIC_SUB = "qciot/ae/new/sub/"             //设备订阅消息
const EMQX_TOPIC_WILL = "qciot/ae/new/will/"           //设备离线消息【已废弃，云端自己维护离线】
const EMQX_TOPIC_AppPub = "qciot/ae/new/appPub/"       // 云端内部订阅手机端消息
const EMQX_TOPIC_WEBSUB = "qciot/ae/v2/webSub/"        // 后面接的是deptId
const EMQX_TOPIC_QC_GW_PUB = "qciot/ae/new/qc_gw_pub/" //清诚网关通信消息-网关发布
const EMQX_TOPIC_QC_GW_SUB = "qciot/ae/new/qc_gw_sub/" //清诚网关通信消息-网关订阅
// mqtt中  0: 获取该设备所有配置信息 1: 启动传输 2: 停止传输 3: 反馈lora传输完成状态，结合lora_complete  4: 重启 5: 休眠 6: AST测试  255:休眠完成  7: 获取设备当前状态 8噪声测试
// 9:vi计划任务 10:唤醒  11恢复出厂设置
const AeMqttStateCmd_0 = 0
const AeMqttStateCmd_1 = 1
const AeMqttStateCmd_2 = 2
const AeMqttStateCmd_3 = 3
const AeMqttStateCmd_4 = 4
const AeMqttStateCmd_5 = 5
const AeMqttStateCmd_6 = 6
const AeMqttStateCmd_7 = 7
const AeMqttStateCmd_8 = 8
const AeMqttStateCmd_9 = 9
const AeMqttStateCmd_10 = 10
const AeMqttStateCmd_11 = 11

// mqtt中设备状态  // 1在线 2离线 3休眠 4唤醒
const AeMqttDeviceStatus_1 = 1
const AeMqttDeviceStatus_2 = 2
const AeMqttDeviceStatus_3 = 3
const AeMqttDeviceStatus_4 = 4

const AeMqttOpResFlagBigFlagOp = "operate"
const AeMqttOpResFlagBigFlagState = "state"
const AeMqttOpResFlagBigFlagFwUpdate = "fwUpdate"

const MqttTagEmqx = 0 // emqx4.4
const MqttTagMochi = 1
